package com.sugar.follow.up.module.business.controller.admin.patient.gzxss.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import javax.validation.constraints.*;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;

import static com.sugar.follow.up.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;

@Schema(description = "管理后台 - 根治性手术新增/修改 Request VO")
@Data
public class PatientGzxssSaveReqVO {

    @Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "8940")
    private Long id;

    @Schema(description = "就诊人ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "14001")
    @NotNull(message = "就诊人ID不能为空")
    private Long patientId;

    @Schema(description = "就诊人姓名（冗余）", requiredMode = Schema.RequiredMode.REQUIRED, example = "芋艿")
    @NotEmpty(message = "就诊人姓名不能为空")
    private String patientName;

    @Schema(description = "手术日期")
    private LocalDate surgeryDate;

    @Schema(description = "术者", example = "芋艿")
    private String surgeryName;

    @Schema(description = "术式（多选：腹腔镜 RP；开放式RP；机器人辅助 RP；筋膜内；筋膜外；前入路；后入路）")
    private List<String> surgeryMethod;

    @Schema(description = "淋巴结清扫情况（多选：未清扫；标准；扩大）")
    private List<String> lbjqsqk;

    @Schema(description = "淋巴结清扫情况左")
    private String lbjqsqkLeft;

    @Schema(description = "淋巴结清扫情况右")
    private String lbjqsqkRight;

    @Schema(description = "是否保留性神经（多选：否、保留左侧、保留右侧）")
    private List<String> sfblxsj;

    @Schema(description = "尿管-留置时间")
    @JsonSerialize(using = LocalDateTimeSerializer.class) // 序列化（响应）
    @JsonDeserialize(using = LocalDateTimeDeserializer.class) // 反序列化（请求）
    @JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
    private LocalDateTime ngLzsj;

    @Schema(description = "尿管-拔出时间")
    @JsonSerialize(using = LocalDateTimeSerializer.class) // 序列化（响应）
    @JsonDeserialize(using = LocalDateTimeDeserializer.class) // 反序列化（请求）
    @JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
    private LocalDateTime ngBcsj;

    @Schema(description = "引流管-留置时间")
    @JsonSerialize(using = LocalDateTimeSerializer.class) // 序列化（响应）
    @JsonDeserialize(using = LocalDateTimeDeserializer.class) // 反序列化（请求）
    @JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
    private LocalDateTime ylgLzsj;

    @Schema(description = "引流管-拔出时间")
    @JsonSerialize(using = LocalDateTimeSerializer.class) // 序列化（响应）
    @JsonDeserialize(using = LocalDateTimeDeserializer.class) // 反序列化（请求）
    @JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
    private LocalDateTime ylgBcsj;

    @Schema(description = "围手术期并发症（多选：无；其它；直肠损失；血管损伤；神经损伤；淋巴漏）")
    private List<String> wssqbfz;

    @Schema(description = "并发症及处理方式")
    private String bfzjclfs;

    @Schema(description = "术后诊断")
    private String shzd;

    @Schema(description = "Gleason 病理")
    private String gleasonBl;

    @Schema(description = "病理结果黏贴处")
    private String bljgntc;

}